#include<stdio.h>
#include<string.h>
#include<assert.h>

char* my_strcpy(char* str1,const char* str2)
{
	assert(str1 && str2);

	char* ret = str2;
	while (*ret)
	{
		*str1++ = *ret++;
	}
	*str1 = '\0';

	return str1;
}

int main()
{
	char arr1[10] = "baiyahua";
	char arr2[10] = { 0 };
	//strcpy(arr2, arr1);
	my_strcpy(arr2, arr1);
	printf("%s\n", arr2);

	return 0;
}